package com.dljd.javase.t10.map;

import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.Set;

public class LinkedHashMapDemo {
    public static void main(String[] args) {
        LinkedHashMap  ls=new LinkedHashMap();
        ls.put("jack3",123);
        ls.put("jack2",56);
        ls.put("rose12",655);
        ls.put("jack234",345);
        ls.put("2342jack",45);
        Set<String> ss=ls.keySet();
        Iterator<String> it=ss.iterator();
        while(it.hasNext()){
            String key=it.next();
            System.out.println(key+":"+ls.get(key));
        }
    }
}
